Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(build): remove need for typesVersions breaking VSCode imports #130

Merged
merged 15 commits into from
Mar 6, 2024

Conversation

charlypoly
Copy link
Contributor

@charlypoly charlypoly commented Mar 5, 2024

Currently, because of the use of typesVersions, VSCode resolves defer imports to @defer/client/index, which causes compilation issues with Next.js:

image image
  • tests ✅ (local and remote)
  • published artifact check
  • local QA on a Next.js project

@charlypoly charlypoly self-assigned this Mar 5, 2024
Copy link

changeset-bot bot commented Mar 5, 2024

🦋 Changeset detected

Latest commit: 49d1049

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@defer/client Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

github-actions bot commented Mar 5, 2024

🚀 Snapshot Release (alpha)

The latest changes of this PR are available as alpha on npm (based on the declared changesets):

Package Version Info
@defer/client 2.3.0-alpha-20240306091527-49d104989dee1ada474ee6863159cb9416b44c98 npm ↗︎ unpkg ↗︎

@charlypoly charlypoly marked this pull request as draft March 5, 2024 09:53
@charlypoly charlypoly marked this pull request as ready for review March 5, 2024 10:12
@charlypoly charlypoly changed the title fix(build): remove need for typesVersions breaking VSCode imports fix(build): remove need for typesVersions breaking VSCode imports Mar 5, 2024
Copy link
Contributor

@gearnode gearnode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The previous release accidentally disabled the test suite for the next part, which is why the CI is green. Renaming the files from .spec.ts to .test.ts pattern will enable the test suite again.

Not providing the file extension in an import statement could cause incompatibility with full ESM project. Can you explain why it's not needed anymore?

@charlypoly
Copy link
Contributor Author

Not providing the file extension in an import statement could cause incompatibility with full ESM project. Can you explain why it's not needed anymore?

@gearnode: It won't because the project is no longer a module (which requires .js imports) and is now compatible with both ESM and CJS. We don't need the project to be a module so I simplified things.

@charlypoly charlypoly merged commit 70cb314 into master Mar 6, 2024
4 checks passed
@gearnode gearnode deleted the fix/build branch March 6, 2024 09:21
@github-actions github-actions bot mentioned this pull request Mar 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants